<p>Пожалуйста, уточните ваши итоговые оценки по пройденным курсам:</p>
<form action="{% url 'content_adm:results' ider.stud_id %}" method="post">
{% csrf_token %}
	<table border="1px">
		<tbody>
			<tr>
				<th>
					Название курса
				</th>
				<th>
					Итоговая оценка
				</th>
				<th>
					Средняя оценка
				</th>
			</tr>
			{% for mark in mark_list %} 
					<tr>
						<td>{{ mark.crs }}</td>
						<td>
							<select name="mark_final_r{{ forloop.counter }}" id="mark_final_r{{ forloop.counter }}">
								<option {% if mark.mark_final = 3 %} selected="selected" {% endif %} >3</option>
								<option {% if mark.mark_final = 4 %} selected="selected" {% endif %} >4</option>
								<option {% if mark.mark_final = 5 %} selected="selected" {% endif %} >5</option>
							</select>
						</td>
						<td>
							<input type="text" name="mark_avg_r{{ forloop.counter }}" readonly="readonly" id="mark_avg_r{{ forloop.counter }}" value="{{ mark.mark_avg }}" />
						</td>
					</tr>
			{% endfor %}

			{% for e_mark in empty_mark_list %} 
				<tr>
					<td>{{ e_mark.crs }}</td>
					<td>
						<select id="mark_final_w{{ forloop.counter }}" name="mark_final_w{{ forloop.counter }}">
							<option>3</option>
							<option>4</option>
							<option>5</option>
						</select>
					</td>
					<td>
						<input type="text" name="mark_avg_w{{ forloop.counter }}" readonly="readonly" id="mark_avg_w{{ forloop.counter }}" value="0" />
					</td>
				</tr>
			{% endfor %} 
		</tbody>
	</table>
	<input type="submit" value="OK" />
</form>
